package com.hr.config;

import com.hr.feign.interceptor.FeignRequestInterceptor;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.annotation.Order;

/**
 * Feign配置
 */

@Configuration
/**
 * 启用feign客户端组件
 * basePackages:开启feign客户端组件之后，重新扫描 basePackages 指定的包
 * defaultConfiguration:我这里配置了feign接口调用的拦截器
 */
@EnableFeignClients(
        basePackages = "com.hr.feign",
        defaultConfiguration = FeignRequestInterceptor.class
)
public class FeignConfig {

}
